#pragma once

#include<windows.h>
#include "Puse.h"
#define ImgType void* 

extern u16 POINT_COLOR;
extern u16 BACK_COLOR;

extern int				Win_Height;
extern int				Win_Width;
extern BOOL             Win_bFullScreen;
#define Win_MSG   MSG
void LCD_Init();
void point_color(u16 color);
void back_color(u16 color);
void LCD_DrawPoint(u16 x, u16 y);
void LCD_point_u16(u16 x, u16 y, u16 color565);
void LCD_DrawPoint_big(u16 x, u16 y);
void LCD_DrawLine(u16 x1, u16 y1, u16 x2, u16 y2);
void Draw_Circle(u16 x0, u16 y0, u8 r);
void LCD_DrawRectangle(u16 x1, u16 y1, u16 x2, u16 y2);
void LCD_Fill(u16 xsta, u16 ysta, u16 xend, u16 yend, u16 color);
void LCD_ShowNum(u16 x, u16 y, u32 num, u8 len);
void LCD_ShowString(u16 x, u16 y, const char *p);
void LCD_Clear(u16 Color);

typedef struct mywindow {
	HWND hWnd;
	HDC hDc;

	HBITMAP hBmp;
	int x, y, width, height;
	unsigned char* imdata;
	void(*init_img)();
	void (*setXY)(void* pthiswin, int x, int y);
	void (*setImg)(void* pthiswin, ImgType myimg);
	void(*free)(void* pthiswindow);
	void (*update)(void* pthiswindow);
} mywindow;
typedef struct mywindow* MyWindow;

typedef struct wincreat {
	MyWindow(*NewWin)(int width, int height);

};
extern struct wincreat WinCreat;

